<template>
  <div class="search-item">
   <div class="left-input">
     <el-input placeholder="please input satellite name of norad number" v-model="searchVal" @input="searchBtn"  clearable @clear="handleClean" />
<!--     <el-button class="bgColor ml10 f14" size="mini" type="primary" icon="el-icon-search" @click="searchBtn">Search</el-button>-->
   </div>
    <div class="back-btn f14" @click="backBtn">
     <i class="iconfont icon-fanhui1"></i> &nbsp;Back
    </div>
  </div>
</template>

<script>
export default {
  name: "commonSearch",
  data(){
    return{
      searchVal:""
    }
  },
  methods:{
    backBtn(){
      this.$router.push("/gdHome")
    },
    searchBtn(){
      this.$emit("searchBtn",this.searchVal)
    },
    handleClean(){
      this.$emit("searchBtn",this.searchVal)
    },

  }
};
</script>

<style scoped lang="scss">
  .search-item{
    padding: 30px 30px 10px 30px;
    box-sizing: border-box;
    display: flex;
    align-items:center;
    justify-content: space-between;
    .bgColor{
      background: #4E9EFF;
    }
    .left-input{
      display: flex;
    }
    .back-btn{
      width: 80px;
      height: 40px;
      background: #525459;
      border-radius: 4px;
      color: #fff;
      display: flex;
      align-items:center;
      justify-content: center;
      cursor: pointer;
    }
  }
  ::v-deep .el-input__inner{
    width: 400px;
    height: 40px;
    background: #18191E;
    border-radius: 4px;
    color: #fff;
    border: 1px solid #353741;
  }
</style>
